using System;
using System.Collections.Generic;
using System.Text;
using System.Data;
using QLNhaSach.DAO;
using QLNhaSach.BUS.DTO;

namespace QLNhaSach.DAO
{
    class NhanVienQuanLyDAO:NhanVienDAO
    {
        //Hien thi danh sach khach hang
        public static DataTable DSKH()
        {
            return KhachHangDAO.DSKH();
        }

        //Them khach hang
        public static bool ThemKhachHang(KhachHangDTO kh)
        { 
            if (KhachHangDAO.ThemTTKH(kh))
            {
                return true;
            }
            else
            {
                return false;
            }
        }

        //Cap nhat thong tin khach hang
        public static bool CapNhatTTKH(KhachHangDTO kh)
        {
            if (KhachHangDAO.CapNhatTTKH(kh))
                return true;
            else
                return false;
        }

        //Hien thi danh sach hoa don
        public static DataTable DanhSachHD()
        {
            return HoaDonDAO.DSHD();    
        }

        //Hien thi tat ca hoa don 1 khach hang
        public static DataTable HDMotKH(KhachHangDTO kh)
        {
            return HoaDonDAO.HDMotKH(kh);
        }

        //Hien thi chi tiet hoa don cua 1 hoa don
        public static DataTable HienThiCTHD(HoaDonDTO hd)
        {
            return ChiTietHoaDonDAO.LayTatCaCTHD(hd);
        }

        //Hien thi danh sach quy dinh
        public static DataTable DSQD()
        {
            return QuyDinhDAO.DSQD();
        }

        //Tao quy dinh
        public static bool TaoQD(QuyDinhDTO qd)
        {
            if (QuyDinhDAO.TaoQD(qd))
                return true;
            else
                return false;
        }

        //Cap nhat quy dinh
        public static bool CapNhatQD(QuyDinhDTO qd)
        {
            if (QuyDinhDAO.CapNhatQD(qd))
                return true;
            else
                return false;
        }
    }
}
